import request from '@/utils/request'

export function getOriginates(query) {
  if(query != undefined){
    query = JSON.parse(JSON.stringify(query))
  }
  return request({
    url: '/knowledge/originate/getList',
    method: 'post',
    data: query
  })
}

export function getOriginateUsableList(query) {
  if(query != undefined){
    query = JSON.parse(JSON.stringify(query))
  }
  return request({
    url: '/knowledge/originate/getUsableList',
    method: 'post',
    data: query
  })
}
export function getOriginate(id) {
  return request({
    url: '/knowledge/originate/getDetail',
    method: 'post',
    data: id
  })
}

export function saveOriginate(formdata) {
  return request({
    url: '/knowledge/originate/save',
    method: 'post',
    data: formdata
  })
}
export function changeStatusByOriginateID(id) {
  return request({
    url: '/knowledge/originate/change-status',
    method: 'post',
    data: id
  })
}

export function removeOriginateByID(id) {
  return request({
    url: '/knowledge/originate/remove',
    method: 'post',
    data: id
  })
}

export function deleteOriginateByID(id) {
  return request({
    url: '/knowledge/originate/delete',
    method: 'post',
    data: id
  })
}
export function getOriginateAvabile() {
  return request({
    url: '/knowledge/originate/getAvailable',
    method: 'post'
  })
}


